//子组件
 
<template>
<div>
 <h3>我是Ref子组件呀！</h3> <br/>
 {{message}}<br>

  {{msg}}

</div>

 
</template>
 
<script>

export default{
    name: "child",
    props: ['message'], //声明一个自定义的属性
    data(){
        return{
            msg:''
        }
    },
    methods:{
        getMsg(m){
            this.msg = m
        }
    }
}
  
</script>